package org.jeecg.desen.run.builder.impl;

import org.jeecg.desen.run.builder.DesBuilder;
import org.jeecg.desen.run.service.DesRunService;
import org.jeecg.desen.run.service.impl.DesRunAutoService;
import org.jeecg.desen.run.service.impl.DesRunManualService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.Date;

@Service
public class DesBuilderImpl implements DesBuilder {

    @Autowired
    DesRunAutoService desRunAutoService;

    @Autowired
    DesRunManualService desRunManualService;

    @Override
    public DesRunService builderAuto(String proNum, Date runDate) {
        return desRunAutoService.bindProNum(proNum, runDate);
    }

    @Override
    public DesRunService builderManual(String sscid, Date runDate) {
        return desRunManualService.bindSscid(sscid, runDate);
    }

    @Override
    public DesRunService builderManual(String sscid, Date runDate, Date endDate) {
        return desRunManualService.bindSscid(sscid, runDate, endDate);
    }
}
